package com.yzh.croom.mapper;

import com.yzh.croom.model.domain.Week;
import org.apache.ibatis.annotations.*;
import org.apache.ibatis.mapping.FetchType;

import java.util.List;

@Mapper
public interface WeekMapper {
    @Results({
            @Result(id = true,column = "week_id",property = "weekId"),
            @Result(column = "week",property = "week")
    })


    @Select("select * from tb_week")
    public List<Week> getAllWeek();

    @Select("select * from tb_week where week_id=#{weekId}")
    public Week getWeekById(int weekId);

}
